<template>
  <el-pagination
    :current-page="pageNum"
    :page-size="pageSize"
    :page-sizes="[5, 10, 20]"
    :background="false"
    layout="prev, pager, next, jumper,->,sizes,total"
    :total="total"
    @current-change="currentChange"
    @size-change="sizeChange"
  ></el-pagination>
</template>
<script setup lang="ts">
defineProps(["pageNum", "pageSize", "total"]);
const $emit = defineEmits(["handleCurrentChange", "handleSizeChange"]);
const currentChange = (val: number) => {
  $emit("handleCurrentChange", val);
};

const sizeChange = (val: number) => {
  $emit("handleSizeChange", val);
};
</script>
<style lang="scss" scoped></style>
